#include <stdio.h>
#include <string.h>
#include <stdlib.h>

int main(int argc, char *argv[], char *env[])
{
   
   if(argc != 4)
   {
      printf("Usage:\n\t%s -[add|sub|mul|div] x y\n\n", argv[0]);
      return 1;
   }

   int x = atoi(argv[2]);
   int y = atoi(argv[3]);

   if(strcmp("-add", argv[1]) == 0)
   {
      printf("%d+%d=%d\n", x, y, x+y);
   }
   else if(strcmp("-sub", argv[1]) == 0)
   {
      printf("%d-%d=%d\n", x, y, x-y);
   }
   else if(strcmp("-mul", argv[1]) == 0)
   {
      printf("%d*%d=%d\n", x, y, x*y);
   }
   else
   {
      printf("unknown!\n");
   }
    return 0;
}
